#include <stdio.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <arpa/inet.h>

int main(int argc,char const* argv[])
{
    in_addr_t addr;
    addr=inet_addr("192.168.1.10");
    printf("addr = %x\n",addr);

    struct in_addr tmp;
    tmp.s_addr = addr;
    printf("ip = %s\n",inet_ntoa(tmp));

    return 0;
}